#include <iostream>
#include <QCoreApplication>
using namespace std;
int main()
{
  int n, k, ch, os;
  do
  {
   cout << "Vvedite chislo N (N > 0): " ;
    cin >> n;
   cout << "Vvedite chislo K (K > 0): " ;
   cin >> k;
  }
  while (n < 0 && k < 0);
  ch = 0;
  while(n >= k)
  {
    ch++;
    n -= k;
  }
  os = n;
  cout << "Chastnoe " << ch << endl;
cout << "Ostatok " << os << endl;
  return 0;
}
